package com.waimai.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import com.waimai.model.User;

@Repository("userdao2")
public interface UserDao2 {

	@Select(value="${sql}")
	@Results(value={
			@Result(id=true,property="id",column="id"),
			@Result(property="username",column="username"),
			@Result(property="password",column="password")
	})
	List<User> findAll(@Param(value="sql") String sql);
}
